#include "appPackage.h"
#include "jsonUtils.h"

AppPackage::AppPackage() : id(0), versionCode(0)
{

}

void AppPackage::fromJson(const JsonValue& value)
{
	JsonUtils::loadLong(value, L"id", id);
	JsonUtils::loadStr(value, L"versionName", versionName);
	JsonUtils::loadInt(value, L"versionCode", versionCode);
}

const String& AppPackage::getVersionName() const
{
	return versionName;
}

const int64_t& AppPackage::getId() const
{
	return id;
}
